<extend name="Public:common" />
<!--/sidebar-->
<block name="content">
    <div class="main-wrap">
        <div class="crumb-wrap">
            <div class="crumb-list"> <i class="icon-font"></i>
                <a href="/Admin">首页</a>
                <span class="crumb-step">&gt;</span>
                <span class="crumb-name">提现管理</span>
            </div>
        </div>
        <div class="search-wrap">
            <div class="search-content">
                <form action="" method="get">
                    <table class="search-tab">
                        <tr>
                         <!--    <th width="120">选择分类:</th>
                            <td>
                                <select name="search" id="">
                                    <option value="">全部</option>
                                    <foreach name="Tarr" item="vo">
                                    <option value="{$vo.tid}">{$vo.tname}</option>
                                    </foreach>
                                </select>
                            </td> -->
                            <th width="70">单号:</th>
                            <td>
                                <input class="common-text" placeholder="订单号" name="keywords" value="" id="" type="text"></td>
                            <td>
                                <input class="btn btn-primary btn2" name="sub" value="查询" type="submit"></td>
                        </tr>
                    </table>
                </form>
            </div>
        </div>
        <div class="result-wrap">
        
                   <?php if(empty($Tarr)){?>
                 <tr ><span style="text-align:center;font-size: 2em"></span>没有交易记录</tr>
                           
                       <?php  die;} ?>
            <form name="myform" id="myform" method="post">
                <div class="result-content">
                    <table class="result-tab" width="100%">
                        <tr>

                            <th>ID</th>
                             <th>订单号</th>
                            <th>昵称</th>
                            <th>姓名</th>
                            <th>金额</th>
                            <th>提现时间</th>
                            <th>状态</th>
                            <th>操作</th>
                            
                           
                            <!-- <th>加入人数</th> -->
                            <!-- <th>操作</th> -->
                        </tr>

                        <foreach name="Tarr" item="vo">
                        <tr>
                        <td>{$vo.mid}</td>
                        <td>{$vo.dan}</td>       
                        <td>{$vo.username}</td>
                        <td>{$vo.muser}</td>
                        <td>{$vo.mshu}</td>
                        <td>{$vo.createtime}</td>
                         <if condition="$vo.mstatus eq 0 ">    
                         <td style="color:green">处理中</td>
                         <elseif condition="$vo.mstatus eq 1"/>
                         <td style="color:green">已到账</td>
                         <elseif condition="$vo.mstatus eq 2"/>
                         <td style="color:green">已打款</td>
                         <else /> <td style="color:red">未通过</td>
                        </if>

                        <!-- <td>{$vo.jiao_type}</td> -->
                        <td> 
                         <if condition="$vo.mstatus eq 0 ">  
                           <a href="javascript:update({$vo.mid},2)" title="">已打款</a>
                           <a href="javascript:update({$vo.mid},3)" title="">未通过</a>
                         <elseif condition="$vo.mstatus eq 2"/>
                         <a href="javascript:update({$vo.mid},1)" title="">已到账</a>
                        </if> 
                        </td>
                    </tr>
                    </foreach>
                </table>
                <div class="list-page">{$page}</div>
            </div>
        </form>
    </div>
</div>
<script type="text/javascript">
function update(id,status) {
    if(confirm("执行后将无法恢复，确定继续吗？温馨提示"))
            {
        $.post('__URL__/upd', {'sid':id,sta:status}, function(data){
           alert(data);
           location.reload([true])  
        });
        exit;
        }
    }
</script>
</block>